﻿<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPageAdmin.master" AutoEventWireup="true" CodeFile="Location.aspx.cs" Inherits="Plublic_Cards" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
    <style type="text/css">
        .style1
        {
            text-align: right;
            color: #FFFFFF;
            font-weight: bold;
            width: 101px;
        }
        .style2
        {
            width: 101px;
        }
    </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
 <form method=post runat=server>
<table style="width: 100%;">
    <tr>
        <td class="style1">
            Address :
        </td>
        <td>
            <asp:TextBox ID="txtAddress" runat="server" ForeColor="#FF5050"></asp:TextBox>
            <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" 
                ControlToValidate="txtAddress" ErrorMessage="RequiredFieldValidator" 
                ForeColor="#FF0066" ValidationGroup="CheckNull">*</asp:RequiredFieldValidator>
        </td>
        <td>
            &nbsp;
        </td>
    </tr>
    <tr>
        <td class="style1">
            Description:
        </td>
        <td>
            <asp:TextBox ID="txtDescriptions" runat="server"></asp:TextBox>
        </td>
        <td>
            &nbsp;
        </td>
    </tr>
    <tr>
        <td class="style2">
            &nbsp;</td>
        <td>
            &nbsp;
            <asp:Button ID="btnAdd" runat="server" Text="Save" onclick="btnAdd_Click" 
                Width="51px" ValidationGroup="CheckNull" />
            <asp:Button ID="Button1" runat="server" onclick="Button1_Click" Text="Update" />
        </td>
        <td>
            &nbsp;
        </td>
    </tr>

    <tr>

     <td colspan=3>
        
        
     </td>
   </tr>

</table>

 <div class="CSSTableGenerator">
     <asp:GridView ID="GRVLocation" runat="server" AutoGenerateColumns="False" 
            DataKeyNames="LocationID"  BackColor="#FFFFCC" Width="70%" onrowcommand="GRVLocation_RowCommand">
            
                <Columns>
                   <asp:TemplateField HeaderText="Location ID">
                       <ItemTemplate>
                        <%# Eval("LocationID")%>
                       </ItemTemplate>
                    
                   </asp:TemplateField>

                   <asp:TemplateField HeaderText="Address">
                       <ItemTemplate>
                        <%# Eval("address")%>
                       </ItemTemplate>
                    
                   </asp:TemplateField>

                   <asp:TemplateField HeaderText="Descriptions">
                       <ItemTemplate>
                        <%# Eval("Descriptions")%>
                       </ItemTemplate>
                    
                   </asp:TemplateField>
                   
                   <asp:TemplateField>
                            <ItemTemplate>
                                <asp:LinkButton ID="lbtnView" runat="server" CausesValidation="False" CommandName="View"
                                    Width="50" Text="View" CommandArgument='<%# DataBinder.Eval(Container, "RowIndex") %>'>
                                </asp:LinkButton>
                            </ItemTemplate>
                   </asp:TemplateField>


                </Columns>

         </asp:GridView>
 </div>          
</form>
</asp:Content>

